//
//  CymController.m
//  Tom
//
//  Created by dllo on 16/6/8.
//  Copyright © 2016年 dllo. All rights reserved.
//

#import "CymController.h"
#import "ViewController.h"
@interface CymController ()

@end

@implementation CymController

- (void)viewDidLoad {
    [super viewDidLoad];
    [self crrr];
   }
-(void)crrr{
   
    UIImageView *anima =[[UIImageView alloc]initWithImage:[UIImage imageNamed:@"cymbal_%d.jpg"]];
    anima.frame = [UIScreen mainScreen].bounds;
    [self.view addSubview:anima];
    [anima release];
    NSMutableArray *muta = [NSMutableArray arrayWithCapacity:12];
    
    for(int i= 0 ; i <= 12;i++){
    
            NSString *name =[NSString stringWithFormat:@"cymbal_%d.jpg",i];
        UIImage *animage = [UIImage imageNamed:name];
        [muta addObject:animage];
            }
    
    anima.animationImages = muta;
    anima.animationDuration = 1;
    
    [anima startAnimating];
}










@end
